package facade;

/**
 * @author dongtao
 * @desc
 * @Data 2021-08-16
 */
public class Facade {
    SubSystem1 subSystem1 = null;
    SubSystem2 subSystem2 = null;
    
    public Facade(SubSystem1 subSystem1,SubSystem2 subSystem2){
        this.subSystem1 = subSystem1;
        this.subSystem2 = subSystem2;
    }
    
    public void on(){
        subSystem1.on();
        subSystem2.on();
    }
    
    public void off(){
        subSystem1.off();
        subSystem2.off();
    }
}
